﻿@model GameViewModel.TheGame

@{
    ViewBag.Title = "Результаты";
    var players = Model.Players.OrderByDescending(p => p.PlayerScore).ToList();
}

<ul data-role="listview" data-inset="true">
    @for (var i = 0; i < players.Count; i++)
    {
        var item = players[i];
        <li>
            @Html.DisplayFor(m => item.Name)
            @Html.DisplayFor(m => item.PlayerScore)
        </li>
    }
</ul>

<ul data-role="listview" data-inset="true">
    <li data-role="list-divider">Меню</li>
    <li>@Html.ActionLink("Начать еще раз", "Index", "Game")</li>
    <li>@Html.ActionLink("Реверс", "Reverse", "Game")</li>
    <li>@Html.ActionLink("Настройки", "Setup", "Home")</li>
</ul>
